<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@page import="java.util.Date"%>
<%@page import="jp.co.lkg.springsmp.common.*"%>
<%@page import="java.text.SimpleDateFormat"%>
<%@ include file="/WEB-INF/jsp/include.jsp"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form"%>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"%>
<%@ taglib prefix="sf" uri="http://www.springframework.org/tags/form"%> 
<c:set var="webctx" value="${pageContext.request.contextPath}" />
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no">
<title></title>
<%SimpleDateFormat number = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); %>
<link rel="stylesheet" href="${webctx}/resources/css/loginstyle.css">
<spring:url value="/resources/js/My97DatePicker/WdatePicker.js" var="WdatePicker" />
<script src="${WdatePicker}"></script>
<spring:url value="/resources/js/register.js" var="register" />
<script src="${register}"></script>
</head>
<body style="background-image: url(${webctx}/resources/images/1.jpg);width:100%;height:100%">

<div class="register-container">
	<h1>欢迎您注册</h1>
	
	<%-- <div class="connect">
		<p>现在时间为：<%=number.format(new Date()) %></p>
	</div> --%>
<form id="registerForm" method="post" name="userinfoForm">
		<input type="hidden" id="contextPath" value="${pageContext.request.contextPath}"/>
		<div>
			<input type="text" name="insertDto.username" id="username"  placeholder="您的用户名" onblur="checkName()"/></br><label id="showWarn1" style="color:red"></label>
		</div>
		<div>
			<input type="password" name="insertDto.userpwd" id="userpwd"  placeholder="输入密码" onblur="checkPwd()" /></br><label id="showWarn2" style="color:red"></label>
		</div>
		<div>
		<input type="radio" name="insertDto.sex" style="width:30px;height:20px" value="男" checked="checked">男
		<input type="radio" name="insertDto.sex" style="width:30px;height:20px" value="女">女
		</div>
		<div>
		    <input class="Wdate" type="text" name="insertDto.birthday" id="birthday" placeholder="点击选择出生年月"  onClick="WdatePicker({el:this,dateFmt:'yyyy-MM-dd'})">
		</div>
		<div>
			<input type="text" name="insertDto.qq" id="qq"  placeholder="输入QQ号"  />
		</div>
		<div>
			<input type="text" name="insertDto.email" id="email"  placeholder="输入邮箱地址" onblur="checkEmail()" /></br><label id="showWarn3" style="color:red"></label>
		</div>
		<div>
			<input type="text" name="insertDto.phone" id="phone"  placeholder="输入电话号码"  onblur="checkPhone()"/></br><label id="showWarn4" style="color:red"></label>
		</div>
		<div>
			<input type="text" name="insertDto.usercard"  id="usercard" placeholder="输入身份证号"  onblur="checkCard()"/></br><label id="showWarn5" style="color:red"></label>
		</div>
		<input type="hidden" name="insertDto.userstatus" value="普通用户">
		
		

		 	地址：<select  id="selectedProvinceCd"   onchange="provinceCdSelectChange()" style="margin-top:20px">
					<option value="9999">请选择省份</option>
					<c:forEach items="${userinfoForm.provinceFieldList}" var="pro">
					
					<option value="${pro.id}">${pro.name}</option>
					</c:forEach>					
				</select>
				<select  id="selectedCityCd" path="selectedCityCd"  name="insertDto.address">
	         <option value="">城市</option>
	         </select>	
	</form>
	<div style="color:red;font-size:20px;font-weight:bold">
	      <%
			String msg = (String)request.getAttribute("msg");
			if (!TextUtils.isEmpty(msg)) {
				%>
				<%= msg %>
				<%
			}
			%>
	 </div>
				
		<button id="submit"  onclick="doRegister()">注 册</button></br>
	
	<a href="http://localhost:8080/Flower/user/test">
		<button type="button" class="register-tis">已经有账号？</button>
	</a>

</div>
<spring:url value="/resources/js/jquery.min.js" var="jquery" />
<script src="${jquery}"></script>
<spring:url value="/resources/js/jquery.validate.min.js?var1.14.0" var="validate" />
<script src="${validate}"></script>

<div style="text-align:center;margin:50px 0; font:normal 14px/24px 'MicroSoft YaHei';">
<p></p>
<p><a href="http://down.admin5.com" target="_blank"></a></p>
</div>
</body>
</html>